home *** CD-ROM | disk | FTP | other *** search
Modula Definition | 1997-04-23 | 2.2 KB | 78 lines | [TEXT/3PRM] |
- definition module deltaSystem;
-
- // Version 0.8 to 1.0
-
- //
- // Operating System dependent constants and functions.
- //
-
- from StdString import String;
-
- /* Keyboard constants */
-
- UpKey :== '\036'; // Arrow up
- DownKey :== '\037'; // Arrow down
- LeftKey :== '\034'; // Arrow left
- RightKey :== '\035'; // Arrow right
- PgUpKey :== '\013'; // Page up
- PgDownKey :== '\014'; // Page down
- BeginKey :== '\001'; // Begin of text
- EndKey :== '\004'; // End of text
- BackSpKey :== '\010'; // Backspace
- DelKey :== '\177'; // Delete
- TabKey :== '\011'; // Tab
- ReturnKey :== '\015'; // Return
- EnterKey :== '\003'; // Enter
- EscapeKey :== '\033'; // Escape
- HelpKey :== '\005'; // Help
-
-
- /* File constants */
-
- DirSeparator :== ':'; // Separator between folder- and filenames in a pathname
-
-
- /* Constants to check which of the Modifiers is down. */
-
- ShiftOnly :== (True,False,False,False);
- OptionOnly :== (False,True,False,False);
- CommandOnly :== (False,False,True,False);
- ControlOnly :== (False,False,False,True);
-
-
- /* The functions HomePath and ApplicationPath prefix the
- filename given to them with the full pathnames of the 'home'
- and 'application' directory.
- These functions have been added for compatibility with the
- Sun version of the Clean system. In the 'home' directory
- settings-files (containing preferences, options etc.) should
- be stored. In the 'application' directory (i.e. the
- directory in which the application resides) files that are
- used read-only by the application (such as help files) should
- be stored.
- On the Macintosh these functions just return the filename
- given to them, which means that the file will be stored in
- the same folder as the application.
- */
-
- HomePath :: !String -> String;
- ApplicationPath :: !String -> String;
-
-
- /* Screen resolution functions. */
-
- MMToHorPixels :: !Real -> Int;
- MMToVerPixels :: !Real -> Int;
- InchToHorPixels :: !Real -> Int;
- InchToVerPixels :: !Real -> Int;
-
- /* Maximum ranges of window PictureDomains:
- MaxScrollWindowSize yields the range at which scrollbars
- are inactive.
- MaxFixedWindowSize yields the range at which the window
- does not change into a ScrollWindow.
- */
-
- MaxScrollWindowSize :: (!Int, !Int);
- MaxFixedWindowSize :: (!Int, !Int);
-